# 使用官方的Nginx镜像
FROM nginx:alpine

# 删除默认的Nginx配置文件
RUN rm -rf /etc/nginx/conf.d/default.conf

# 将本地的自定义Nginx配置文件复制到Nginx配置目录
COPY nginx.conf /etc/nginx/conf.d/

# 将本地的dist目录复制到Nginx的html目录
COPY dist /usr/share/nginx/html

# 暴露80端口
EXPOSE 80

# 启动Nginx
CMD ["nginx", "-g", "daemon off;"]